<?php
/******************************
 * EQdkp
 * Copyright 2002-2003
 * Licensed under the GNU GPL.  See COPYING for full terms.
 * ------------------
 * FFXI.php
 * Began: November 2007
 *
 *
 ******************************/

if ( !defined('EQDKP_INC') )
{
    die('Hacking attempt');
}

class Manage_Game extends EQdkp_Admin
{

 function do_it()
 {

   global $db, $eqdkp, $user;
   global $SID, $dbname, $table_prefix;


   parent::eqdkp_admin();


$queries = array(

"TRUNCATE TABLE ". $table_prefix ."classes;",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (0, 'Unknown', 'Unknown', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (1, 'Warrior', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (2, 'White Mage', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (3, 'Monk', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (4, 'Black Mage', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (5, 'Thief', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (6, 'Red Mage', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (7, 'Paladin', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (8, 'Dark Knight', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (9, 'Beastmaster', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (10, 'Bard', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (11, 'Ranger', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (12, 'Samurai', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (13, 'Ninja', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (14, 'Dragoon', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (15, 'Summoner', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (16, 'Blue Mage', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (17, 'Corsair', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (18, 'Puppetmaster', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (19, 'Dancer', 'armor_type', '1', '75');",
"INSERT INTO ". $table_prefix ."classes (class_id, class_name, class_armor_type, class_min_level, class_max_level) VALUES (20, 'Scholar', 'armor_type', '1', '75');",

"TRUNCATE TABLE ". $table_prefix ."races;",

"INSERT INTO ". $table_prefix ."races (race_id, race_name) VALUES (0, 'Unknown');",
"INSERT INTO ". $table_prefix ."races (race_id, race_name) VALUES (1, 'Elvaan');",
"INSERT INTO ". $table_prefix ."races (race_id, race_name) VALUES (2, 'Mithra');",
"INSERT INTO ". $table_prefix ."races (race_id, race_name) VALUES (3, 'Galka');",
"INSERT INTO ". $table_prefix ."races (race_id, race_name) VALUES (4, 'Tarutaru');",
"INSERT INTO ". $table_prefix ."races (race_id, race_name) VALUES (5, 'Hume');",

"TRUNCATE TABLE ". $table_prefix ."factions;",

"INSERT INTO ". $table_prefix ."factions (faction_id, faction_name) VALUES (1, 'Bastok');",
"INSERT INTO ". $table_prefix ."factions (faction_id, faction_name) VALUES (2, 'Windurst');",
"INSERT INTO ". $table_prefix ."factions (faction_id, faction_name) VALUES (3, 'Sandoria');",

);


   foreach ( $queries as $sql )
   {
       $db->query($sql);
   }


 $redir = "admin/config.php";
 redirect($redir);

 }

}

$manage = new Manage_Game;
$manage->do_it();


?>

